import http from '@/utils/http/index';

//获取热搜top5
export const getTopSearchKeyWords = (params: { topNum: number }) => {
  const { topNum } = params;
  return http.get(`top-search-keyword/${topNum}`);
};

/**
 * 获取指标库列表数据
 */
export type IndexLibListParam = {
  content?: string;
  order?: number;
  pageNum: number;
  pageSize: number;
  sortBy?: string;
  subjectId?: string;
};
export const getIndexLibListData = (
  params: IndexLibListParam = { pageSize: 20, pageNum: 1 }
) => {
  return http.get(`/metricsx/api/v1/metrics-library/list`, params);
};

// 收藏 取消收藏见api/index.ts
